package edu.scau.comeva.rigcontrol.entity;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Set;

/**
 * Created with IntelliJ IDEA.
 * User: Dan
 * Date: 13-8-18
 * Time: 上午1:01
 * To change this template use File | Settings | File Templates.
 */
@Entity
@Table
public class m_class implements Serializable {
    private long class_id;
    private String class_name;
    private String class_depart;
    private Set<m_student> class_students;
    private m_deterTeam determainTeam;

    @Id
    @GeneratedValue
    public long getClass_id() {
        return class_id;
    }

    public void setClass_id(long class_id) {
        this.class_id = class_id;
    }

    public String getClass_name() {
        return class_name;
    }

    public void setClass_name(String class_name) {
        this.class_name = class_name;
    }

    public String getClass_depart() {
        return class_depart;
    }

    public void setClass_depart(String class_depart) {
        this.class_depart = class_depart;
    }

    @OneToMany(mappedBy = "student_class")
    public Set<m_student> getClass_students() {
        return class_students;
    }

    public void setClass_students(Set<m_student> class_students) {
        this.class_students = class_students;
    }

    @OneToOne(mappedBy = "deterTeam_class")
    public m_deterTeam getDetermainTeam() {
        return determainTeam;
    }

    public void setDetermainTeam(m_deterTeam determainTeam) {
        this.determainTeam = determainTeam;
    }
}
